package cn.com.taiji.pos.mapper;

import cn.com.taiji.pos.entity.ConfigBusinessType;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 * 业务类型(参考SCM系统) Mapper 接口
 * </p>
 *
 * @author
 * @since 2021-03-01
 */
public interface ConfigBusinessTypeMapper extends BaseMapper<ConfigBusinessType> {


    @Select("select a.CODE,a.NAME,a.ID " +
            "FROM config_business_type a inner join CONFIG_POS_BUSINESS_TYPE b on a.id=b.BUSINESS_TYPE_ID " +
            "inner join SYSTEM_POS_MACHINE c on b.POS_MACHINE_ID=c.id " +
            "where c.PHYSICAL_CODE= #{physicalCode}")
    List<ConfigBusinessType> GetListForType(String physicalCode);

}
